using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.DirectX;

namespace OpenPanekitEditor
{
    public struct AABB
    {
        public Vector3 Min;
        public Vector3 Max;
        public void Marge(Vector3 pos)
        {
            if (Min.X > pos.X) Min.X = pos.X;
            if (Min.Y > pos.Y) Min.Y = pos.Y;
            if (Min.Z > pos.Z) Min.Z = pos.Z;
            if (Max.X < pos.X) Max.X = pos.X;
            if (Max.Y < pos.Y) Max.Y = pos.Y;
            if (Max.Z < pos.Z) Max.Z = pos.Z;
        }
        public void Init()
        {
            Min.X = Min.Y = Min.Z =  float.MaxValue;
            Max.X = Max.Y = Max.Z = -float.MaxValue;
        }
    }
}
